/*
 * This class is a bean for containing information and results about a DVD
 * search.
 */

package com.cheapflix.beans;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

/**
 * Bean class that holds all 
 * information pertinent to a search criteria, used in flick search
 * @author Group B
 */
public class SearchCriteria implements Serializable {

    private List<DVD> dvds;

    private int startIndex;

    private int endIndex;

    private String basicSearch;

    private String title;

    private String genre;

    private String actors;

    private String director;

    public SearchCriteria() {
        this.dvds = new ArrayList<DVD>();
        this.startIndex = 0;
        this.endIndex = 0;
        this.basicSearch = "";
    }

    public List<DVD> getDvds() {
        return this.dvds;
    }

    public void setDvds(List<DVD> dvds) {
        if (null != dvds) {
            this.dvds = dvds;
        }
    }

    public int getStartIndex() {
        return this.startIndex;
    }

    public void setStartIndex(int index) {
        this.startIndex = index;
    }

    public int getEndIndex() {
        return this.endIndex;
    }

    public void setEndIndex(int index) {
        this.endIndex = index;
    }

    public int getTotalResults() {
        return this.dvds.size();
    }

    public String getBasicSearch() {
        return basicSearch;
    }

    public void setBasicSearch(String basicSearch) {
        this.basicSearch = basicSearch;
    }

    public String getDirector() {
        return director;
    }

    public void setDirector(String director) {
        this.director = director;
    }

    public String getActors() {
        return actors;
    }

    public void setActors(String actors) {
        this.actors = actors;
    }

    public String getGenre() {
        return genre;
    }

    public void setGenre(String genre) {
        this.genre = genre;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }
}
